/*
This file contains the main function used to test the DDMCMC algorithm.
*/

#include <fstream>
#include <iostream>
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include "ddmcmc.h"

using namespace std;
using namespace cv;

// load the image in the BGR format
Mat readImage(char* filename) {
	Mat img = imread(filename, CV_LOAD_IMAGE_COLOR);

	if (img.data) {
		namedWindow("Display Window", WINDOW_AUTOSIZE);
		imshow("Display Window", img);
		waitKey(0);
	}
	return img;
}

int main(int argc, char** argv) {
	//Mat img = imread("D:/Works/Research/DDMCMC/Test/test.bmp");
	Mat img = imread("../image/guy.jpg");
	//Mat img = imread("../image/test1.bmp");
	//Mat img = imread("../image/guy.jpg", CV_LOAD_IMAGE_COLOR);
	if (!img.data){
		exit(1);
	}

	DDMCMCSegmentation(img);

	return 0;
}
